package com.jbit.utils;

import org.springframework.util.DigestUtils;

import java.io.UnsupportedEncodingException;

public class Md5Utils {
    public static String generalKey(String text) {
        try {
            return DigestUtils.md5DigestAsHex(text.getBytes("utf-8"));
        } catch (UnsupportedEncodingException e) {
            e.printStackTrace();
        }
        return null;
    }
}
